<include file="Public:header" />

<script type="text/javascript" src="__PUBLIC__/statics/js/common.js"></script>
<script type="text/javascript">
	$(document).ready(function(){
		$("#submit").click(function(){
			if($("#name").val()==0){
			   alert('请填写分类名称');
			   return false;
			}
		});
	});
</script>

</head>
<form action="{:U('ItemsCate/add')}" method="post" name="myform" id="myform"  enctype="multipart/form-data" style="margin-top:10px;">
  <div class="pad-10">
    <div class="col-tab">
      <ul class="tabBut cu-li">
        <li id="tab_setting_1" class="on" onclick="SwapTab('setting','on','',2,1);">基本信息</li>
        <li id="tab_setting_2" onclick="SwapTab('setting','on','',2,2);">SEO设置</li>
      </ul>
      <div id="div_setting_1" class="contentList pad-10">
        <table width="100%" cellpadding="2" cellspacing="1" class="table_form">
        <tr>
            <th>上级分类：</th>
            <td>
            <select name="pid" style="width:150px;">
                  <option value="0" <if condition="$cate.pid eq 0">selected="selected"</if>>--顶级分类--</option>
                  <volist name="cates_list['parent']" id="val">
                  <option value="{$val.id}" <if condition="$cate.pid eq $val['id']">selected="selected"</if>>{$val.name}</option>
                  	<!-- <volist name="cates_list['sub'][$val['id']]" id="sval">
                  	<option value="{$sval.id}" <if condition="$cate.pid eq $sval['id']">selected="selected"</if>>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{$sval.name}</option>
                  	</volist> -->
                  </volist>
            </select>
            </td>
          </tr>
          <tr> 
            <th width="100">分类名称 :</th>
            <td><input type="text" name="name" id="name" class="input-text"></td>
          </tr>
          <tr>
          	<th>分类图片 :</th>
            <td>
            	<img style="width:50px;height:50px;border: 1px solid #999999;padding:1px;" /><br /><br />
            	<input type="file" name="img" id="img" class="input-text" size=21 style="height:25px;"/>
            </td>
          </tr>          
          <tr>
            <th width="100">排序值 :</th>
            <td><input type="text" name="ordid" id="ordid" class="input-text" size="4" onkeyup="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')"></td>
          </tr>
          <tr>
            <th>首页显示 :</th>
             <td>
             	<input type="radio" name="is_hots" class="radio_style" value="1"> &nbsp;是&nbsp;&nbsp;&nbsp;
        		<input type="radio" name="is_hots" class="radio_style" value="0" checked="checked"> &nbsp;否
             </td>
          </tr>
		  <tr>
            <th>是否删除 :</th>
             <td>
             	<input type="radio" name="is_del" id="is_del" class="radio_style" value="1" > &nbsp;是&nbsp;&nbsp;&nbsp;
        		<input type="radio" name="is_del" id="is_del" class="radio_style" value="0" checked="checked"> &nbsp;否
             </td>
          </tr>
          
        </table>
      </div>
      
      <div id="div_setting_2" class="contentList pad-10 hidden">
        <table width="100%" cellpadding="2" cellspacing="1" class="table_form">
          <tr>
            <th width="100">Title :</th>
            <td><input type="text" name="seo_title" id="seo_title" class="input-text" value="{$items_cate_info.seo_title}" size="50"></td>
          </tr>
          <tr>
            <th width="100">Keywords :</th>
            <td><input type="text" name="seo_keys" id="seo_keys" class="input-text" value="{$items_cate_info.seo_keys}" size="50"></td>
          </tr>
          <tr>
            <th width="100">Description :</th>
            <td><textarea name="seo_desc" cols="47" rows="4">{$items_cate_info.seo_desc}</textarea></td>
          </tr>
        </table>
      </div>
      <div class="bk15"></div>
      <div class="btn"><input type="submit" value="提交" name="submit" class="button" id="submit"></div>
    </div>
  </div>
</form>
</body></html>